import http from '@/utils/http.js';
/**
 * 接口基本配置
 */
const options = {
	// baseUrl: 'http://192.168.3.198:140',
	baseUrl: 'https://szr.zhim123.com',
	// 拦截器
	interceptor: {
		request: (config) => {
			// console.log(config);
			return config;
		},
		response: (res) => {
			// console.log(res);
			return res;
		}
	},
	complete: () => {
		// console.log('接口调用完成了')
	}
};
/**
 * 定义接口
 */
const api = {
	// 账号服务
	account: {
		wxsmalllogin: params => http.post(options, '/api/account/wxsmalllogin', params),
		testlogin: params => http.post(options, '/api/account/testlogin', params),
		checklogin: params => http.get(options, '/api/account/checklogin', params),
		getuserinfo: params => http.get(options, '/api/account/getuserinfo', params),
		getusersensitiveinfo: params => http.get(options, '/api/account/getusersensitiveinfo', params),
		getassetamount: params => http.get(options, '/api/account/getassetamount', params),
		getassetpackagelist: params => http.get(options, '/api/account/getassetpackagelist', params),
		getassetrecord: params => http.get(options, '/api/account/getassetrecord', params),
		usecdkey: params => http.post(options, '/api/account/usecdkey', params),
		getmywxsmallloginqrcodestate: params => http.get(options, '/api/account/getmywxsmallloginqrcodestate',
			params),
		confirmwxsmallloginqrcode: params => http.post(options, '/api/account/confirmwxsmallloginqrcode',
			params),
	},
	// 剪辑服务
	clip: {
		getcliptasklist: params => http.get(options, '/api/clip/getcliptasklist', params),
		getcliptaskqueuelist: params => http.get(options, '/api/clip/getcliptaskqueuelist', params),
		getclipsubtasklist: params => http.get(options, '/api/clip/getclipsubtasklist', params), //新
		querycliptask: params => http.get(options, '/api/clip/querycliptask', params),
		submitvoicetask: params => http.post(options, '/api/clip/submitvoicetask', params),
		submitdigitaltask: params => http.post(options, '/api/clip/submitdigitaltask', params),
		deletecliptask: params => http.post(options, '/api/clip/deletecliptask', params),

	},
	//克隆服务
	clone: {
		getvoicemodellist: params => http.get(options, '/api/clone/getvoicelist', params),
		getdigitalmodellist: params => http.get(options, '/api/clone/getdigitallist', params),
		submitvoicemodel: params => http.post(options, '/api/clone/submitvoice', params),
		submitdigitalmodel: params => http.post(options, '/api/clone/submitdigital', params),
		applyuploaddigital: params => http.post(options, '/api/clone/applyuploaddigital', params),
		applyuploadvoice: params => http.post(options, '/api/clone/applyuploadvoice', params),
		deletevoice: params => http.post(options, '/api/clone/deletevoice', params),
		deletedigital: params => http.post(options, '/api/clone/deletedigital', params),
		// 提交数字人模型（V2）
		submitdigital2: params => http.post(options, '/api/clone/submitdigital2', params),
		applyuploaddigitalauth: params => http.post(options, '/api/clone/applyuploaddigitalauth', params),
		getauthdigitallist: params => http.get(options, '/api/clone/getauthdigitallist', params),
		setauthdigital: params => http.post(options, '/api/clone/setauthdigital', params),
		getway: params => http.get(options, '/api/clone/getway', params),


	},
	//背景音乐服务
	music: {
		getmusiclist: params => http.get(options, '/api/music/getmusiclist', params),
		getmusic: params => http.get(options, '/api/music/getmusic', params),
	},
	aichat: {
		gettemplatetype: params => http.get(options, '/api/aichat/gettemplatetype', params),
		gettemplate: params => http.get(options, '/api/aichat/gettemplate', params),
		qwen: params => http.post(options, '/api/aichat/qwen', params),
		qwenAll: params => http.post(options, '/api/aichat/all', params),
		getmodel: params => http.get(options, '/api/aichat/getmodel', params),
	},
	userfile: {
		geturl: params => http.get(options, '/api/mate/geturl', params),
	},
	mate: {
		getfontlist: params => http.get(options, '/api/mate/getfontlist', params),
		getmatelist: params => http.get(options, '/api/mate/getmatelist', params),
		geturl: params => http.get(options, '/api/mate/geturl', params),
		applyuploadaudio: params => http.post(options, '/api/mate/applyuploadaudio', params),
		applyuploadmusic: params => http.post(options, '/api/mate/applyuploadmusic', params),
	},
	language: {
		languagelist: params => http.get(options, '/api/language/list', params),
		checktext: params => http.post(options, '/api/language/checktext', params),
	},
	pip: {
		applyuploadvideo: (params) => http.post(options, '/api/pip/applyuploadvideo', params),
		applyuploadimage: (params) => http.post(options, '/api/pip/applyuploadimage', params),
		getpiplist: (params) => http.get(options, '/api/pip/getpiplist', params),
		getpip: (params) => http.get(options, '/api/pip/getpip', params),
		savepip: (params) => http.post(options, '/api/pip/savepip', params),
		deletepip: (params) => http.post(options, '/api/pip/deletepip', params)
	}
};
export default api;